
public class MyStringTest {
    public static void main(String[] args) {
        String int1 ="hello java";
        String int2 ="hello java";

        if (int1.equals(int2)){
            String i = int1.replace(" ", "");
            System.out.println(i);
            String i2 = int1.replace("java","word");
            System.out.println(i2);
        }
    }
}
